﻿using Ecommerce.Domain;
using Ecommerce.Repository.Interface.User;
using Microsoft.EntityFrameworkCore;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Linq.Expressions;
using System.Text;
using System.Threading.Tasks;

namespace Ecommerce.Repository.Impl.Use
{
    public class RoleRepository : BaseRepository<Role>, IRoleRepository
    {
        public RoleRepository(EFContext context) : base(context)
        {
        }
        public async Task<int> AddAsync(Role role)
        {
            return await base.AddAsync(role);
        }

        public async Task<List<Role>> GetAllAsync()
        {
            return await base.GetAllAsync();
        }

        public async Task<List<Role>> GetAsync(Expression<Func<Role, bool>> expre)
        {
            return await base.GetAsync(expre);
        }

        public async Task<Role> GetModelAsync(int id)
        {
            return await base.GetModelAsync(id);
        }

        public async Task<int> Update(Role role)
        {
            return await base.Update(role);
        }
    }
}
